package com.xu.tools.config.mq;

import org.springframework.amqp.rabbit.core.RabbitTemplate;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * @author xuguan
 * @date 2023/4/8
 * @desc
 */
@Component
public class SendMqTestComponent {
    @Autowired
    RabbitTemplate rabbitTemplate;

    public void sendMq() {
        rabbitTemplate.convertAndSend("sms-event-exchange", "sms.send", "hello world");
    }
}
